<?php

namespace App\Http\Controllers\Api;

use App\Http\Controllers\Controller;
use App\Http\Requests\UserContext;
use App\Http\Services\OrderService;
use App\Http\Traits\ResponseJson;

class OrderController extends Controller
{
    use ResponseJson;

    protected $orderService;

    public function __construct(OrderService $orderService)
    {
        $this->orderService = $orderService;
    }

    public function lists(UserContext $userContext)
    {
        $data = $this->orderService->lists($userContext);
        return $this->returnJson($data);
    }

}
